<?php
$this->breadcrumbs = array(
    'ShoppingCarts' => array('index'),
    'Manage',
);
?>

<div class="widget">
    <div class="head">
        <h5 class="iFrames">Shopping Cart List</h5>
    </div>
    <div class="body">
        <!-- Dynamic table -->
        <div class="table">
            <div class="head"><h5 class="iFrames">Carts</h5></div>
            <table cellpadding="0" cellspacing="0" border="0" class="display" id="example">
                <thead>
                    <tr>
                        <th>Order Id</th>
                        <th>Product Id</th>
                        <th>Name</th>
                        <th>Quantity</th>
                        <th>Commands</th>
                    </tr>
                </thead>
                <tbody>
                    <?php foreach ($items as $item): ?>
                        <tr>
                            <td class="center"><?php echo $item->orderId; ?></td>
                            <td class="center"><?php echo $item->productId; ?></td>
                            <td class="center"><?php echo $item->name; ?></td>
                            <td class="center"><?php echo $item->quantity; ?></td>
                            <td class="center"><?php echo CHtml::link(CHtml::image(Yii::app()->request->baseUrl . Constant::CRUD_IMAGE_URL_VIEW), array('order/viewitem', 'productId' => $item->productId, 'orderId' => $item->orderId)); ?></td>
                        </tr>
                    <?php endforeach; ?>
                </tbody>
            </table>
        </div>
    </div>
</div>